package cm.epet.service.impl;

import java.sql.SQLException;
import java.util.ArrayList;

import cm.epet.dao.impl.PetOwnerDAO;
import cm.epet.model.Pet;
import cm.epet.model.PetOwner;
import cm.epet.service.Interface.IPetOwnerService;

public class PetOwnerService implements IPetOwnerService{
	PetOwnerDAO pod;
	public PetOwnerService() throws SQLException {
		pod = new PetOwnerDAO();
	}
	public double buy(Pet pet,PetOwner po) throws SQLException {
		return pod.buy(pet,po);
	}
	public double sell(Pet pet,PetOwner po,String petstorename) throws SQLException {
		return pod.sell(pet,po,petstorename);
	}
	public PetOwner login(String name, String password) throws SQLException {
		return pod.login(name,password);
	}
	public ArrayList<String> displayMyPet(PetOwner po) throws SQLException {
		return pod.displayMyPet(po);
	}
	public ArrayList<String> displayAvailable(PetOwner po) throws SQLException {
		// TODO Auto-generated method stub
		return pod.displayAvailable(po);
	}
	public ArrayList<String> getAllOwner() throws SQLException{
		return pod.getAllOwner();
		
	}
	
}
